package com.lqfan.autoAnswerQ.service.subject;

import com.baomidou.mybatisplus.extension.plugins.pagination.Page;
import com.lqfan.autoAnswerQ.model.fileType.FileType;
import com.lqfan.autoAnswerQ.model.quesBank.QuesBankModel;
import com.lqfan.autoAnswerQ.model.quesBank.Question;
import com.lqfan.autoAnswerQ.model.subject.HandleImportModel;
import com.lqfan.autoAnswerQ.model.subject.Subject;
import com.baomidou.mybatisplus.extension.service.IService;
import com.lqfan.autoAnswerQ.model.subjectChoiceType.SubjectChoiceType;

import java.util.ArrayList;
import java.util.List;

/**
 * <p>
 *  服务类
 * </p>
 *
 * @author lqfan
 * @since 2020-04-04
 */
public interface ISubjectService extends IService<Subject> {

    String saveSubjects(String questionId, int typeId, String content);

    boolean saveHandle(ArrayList<Subject> subList, ArrayList<SubjectChoiceType> choiceList);

    boolean saveHandle(ArrayList<HandleImportModel> handleImportModels, Question quesBank, FileType fileType);

    QuesBankModel getSubjectWithPage(QuesBankModel quesBankModel, String userId, String questionId, int currentPage, int limit);

    QuesBankModel getOneSubject(QuesBankModel quesBankModel,String userId, String subjectId);

    List<Subject> getCollectSubject(String userId);

    int collectSub(Integer isCollect,String id,String userId);
}
